Skip to content

feat(core): real mcp_tool/agent hook handlers + 2 final reminder types#25

Merged
oratis merged 1 commit into
mainfrom
feat/hook-handlers-and-reminders
May 28, 2026
Merged

feat(core): real mcp_tool/agent hook handlers + 2 final reminder types#25
oratis merged 1 commit into
mainfrom
feat/hook-handlers-and-reminders

Conversation

@oratis

@oratis oratis commented May 28, 2026

Copy link
Copy Markdown
Owner

Hook dispatcher gains mcpToolDispatcher + agentDispatcher callbacks (host CLI wires them). 2 new reminders (plan-mode-active, no-test-yet) complete the 7-type plan. 412 passing.

… types

  · packages/core/src/hooks/dispatcher.ts:
    - HookDispatcherOpts gains mcpToolDispatcher? and agentDispatcher?
      callbacks. Host CLI wires these once MCP/sub-agents are loaded.
    - mcp_tool case: dispatches when wired, includes the hook event+payload
      as `arguments`; gracefully reports "no dispatcher" otherwise.
    - agent case: dispatches when wired; same fallback message.
    - Validates handler.server/tool/agent fields before dispatching.

  · packages/core/src/reminders/index.ts:
    - planModeActiveReminder — fires when ctx.mode === 'plan'; nudges
      ExitPlanMode. Hooks into the 7-type plan.
    - noTestYetReminder — fires when editsSinceTests > 0 and either no
      lastTestRunAt or it's > 10min stale.
    - ALL_TYPES and ReminderType union updated.

Tests: core 356 → 365 (+9: 5 reminder + 4 hook); cli 47 unchanged.
Total 403 → 412.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@oratis oratis merged commit 7354e51 into main May 28, 2026
@oratis oratis deleted the feat/hook-handlers-and-reminders branch May 28, 2026 05:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant